LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)

#FFMPEG_LIB=$(LOCAL_PATH)
FFMPEG_INCLUDE=../../include/ffmpeg

include $(CLEAR_VARS)
LOCAL_MODULE:= libavcodec
LOCAL_SRC_FILES:= $(TARGET_ARCH_ABI)/libavcodec.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libavformat
LOCAL_SRC_FILES:= $(TARGET_ARCH_ABI)/libavformat.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libavutil
LOCAL_SRC_FILES:= $(TARGET_ARCH_ABI)/libavutil.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libvo-aacenc
LOCAL_SRC_FILES:=$(TARGET_ARCH_ABI)/libvo-aacenc.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libvo-amrwbenc
LOCAL_SRC_FILES:=$(TARGET_ARCH_ABI)/libvo-amrwbenc.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libavfilter
LOCAL_SRC_FILES:=$(TARGET_ARCH_ABI)/libavfilter.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libavresample
LOCAL_SRC_FILES:= $(TARGET_ARCH_ABI)/libavresample.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libswresample
LOCAL_SRC_FILES:=$(TARGET_ARCH_ABI)/libswresample.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

#include $(CLEAR_VARS)
#LOCAL_MODULE:= libpostproc
#LOCAL_SRC_FILES:=$(TARGET_ARCH_ABI)/libpostproc.a
#LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
#include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libswscale
LOCAL_SRC_FILES:= $(TARGET_ARCH_ABI)/libswscale.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libass
LOCAL_SRC_FILES:=$(TARGET_ARCH_ABI)/libass.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libfreetype
LOCAL_SRC_FILES:=$(TARGET_ARCH_ABI)/libfreetype.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE:= libfribidi
LOCAL_SRC_FILES:=$(TARGET_ARCH_ABI)/libfribidi.a
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE := libffmpeg
LOCAL_SRC_FILES := $(TARGET_ARCH_ABI)/libffmpeg.so
LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
include $(PREBUILT_SHARED_LIBRARY)




ifeq ($(TARGET_ARCH) ,x86)
	include $(CLEAR_VARS)
	LOCAL_MODULE :=  libyuv2
	LOCAL_SRC_FILES := $(TARGET_ARCH_ABI)/libyuv2.so
	LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
	include $(PREBUILT_SHARED_LIBRARY)
else
	include $(CLEAR_VARS)
	LOCAL_MODULE :=  libyuv2
	LOCAL_SRC_FILES :=$(TARGET_ARCH_ABI)/libyuv2.so
	LOCAL_EXPORT_C_INCLUDES := $(FFMPEG_INCLUDE)
	include $(PREBUILT_SHARED_LIBRARY)
endif
